export default [
  {
    path: '',
    redirect: '/home'
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('@/views/login/index.vue')
  },
  // 所有未知页面都是404
  {
    path: '/:catchAll(.*)',
    component: () => import('@/views/404.vue')
  },
  {
    component: () => import('@/layouts/index.vue'),
    children: [
      {
        path: '/userinfo',
        name: 'userinfo',
        meta: {
          title: '个人信息'
        },
        component: () => import('@/views/system/userinfo.vue')
      },
      {
        path: '/editpassword',
        name: 'editpassword',
        meta: {
          title: '修改密码'
        },
        component: () => import('@/views/system/editpassword.vue')
      }
    ]
  }
]
